package com.dindang.propertyfee.di.module;

import com.jess.arms.di.scope.ActivityScope;

import dagger.Module;
import dagger.Provides;

import com.dindang.propertyfee.mvp.contract.OwnerSearchContract;
import com.dindang.propertyfee.mvp.model.OwnerSearchModel;


@Module
public class OwnerSearchModule {
    private OwnerSearchContract.View view;

    /**
     * 构建OwnerSearchModule时,将View的实现类传进来,这样就可以提供View的实现类给presenter
     *
     * @param view
     */
    public OwnerSearchModule(OwnerSearchContract.View view) {
        this.view = view;
    }

    @ActivityScope
    @Provides
    OwnerSearchContract.View provideOwnerSearchView() {
        return this.view;
    }

    @ActivityScope
    @Provides
    OwnerSearchContract.Model provideOwnerSearchModel(OwnerSearchModel model) {
        return model;
    }
}